home *** CD-ROM | disk | FTP | other *** search
/ Aminet 48 / Aminet 48 (2002)(GTI - Schatztruhe)[!][Apr 2002].iso / Aminet / text / edit / vim60rt.lha / Vim / vim60 / syntax / hercules.vim < prev    next >
Encoding:
Text File  |  2001-09-02  |  6.2 KB  |  131 lines

  1. " Vim syntax file
  2. " Language:    Hercules (Avant! Corporation)
  3. " Maintainer:    Dana Edwards <Dana_Edwards@avanticorp.com>
  4. " Extensions:   *.vc,*.ev,*.rs,*.sum,*.errsum
  5. " Last change:  03/01/2001
  6. " Comment:      Hercules physical IC design verification software ensures
  7. "        that an IC's physical design matches its logical design and
  8. "        satisfies manufacturing rules.
  9.  
  10. " Quit when a syntax file was already loaded
  11. if exists("b:current_syntax")
  12.   finish
  13. endif
  14.  
  15. " Ignore case
  16. syn case ignore
  17.  
  18. " Hercules runset sections
  19. syn match   herculesType    "^\s*\t*header"
  20. syn match   herculesType    "^\s*\t*options"
  21. syn match   herculesType    "^\s*\t*alias"
  22. syn match   herculesType    "^\s*\t*assign"
  23. syn match   herculesType    "^\s*\t*assign_property"
  24. syn match   herculesType    "^\s*\t*waiver"
  25. syn match   herculesType    "^\s*\t*.*_options"
  26. syn match   herculesType    "^\s*\t*check_point"
  27. syn match   herculesType    "^\s*\t*compare_group"
  28. syn match   herculesType    "^\s*\t*environment"
  29. syn match   herculesType    "^\s*\t*grid_check"
  30. syn match   herculesType    "^\s*\t*include"
  31. syn match   herculesType    "^\s*\t*layer_stats"
  32. syn match   herculesType    "^\s*\t*load_group"
  33. syn match   herculesType    "^\s*\t*.*run_only"
  34. syn match   herculesType    "^\s*\t*restart"
  35. syn match   herculesType    "^\s*\t*self_intersect"
  36. syn match   herculesType    "^\s*\t*set "
  37. syn match   herculesType    "^\s*\t*set\t"
  38. syn match   herculesType    "^\s*\t*snap"
  39. syn match   herculesType    "^\s*\t*system"
  40. syn match   herculesType    "^\s*\t*variable"
  41.  
  42. " Hercules commands and keywords
  43. syn match   herculesstatement   "^ *\(attach_property\|boolean\|cell_extent\)"
  44. syn match   herculesstatement   "^ *\(common_hierarchy\|connection_points\|size_rect\)"
  45. syn match   herculesstatement   "^ *\(copy\|data_filter\|alternate\|delete\)"
  46. syn match   herculesstatement   "^ *\(explode\|explode_all\|find_net\|flatten\)"
  47. syn match   herculesstatement   "^ *\(fill_pattern\|rectangles\|select_contains\)"
  48. syn match   herculesstatement   "^ *\(level\|negate\|polygon_features\|push\)"
  49. syn match   herculesstatement   "^ *\(relocate\|remove_overlap\|reverse\|select\)"
  50. syn match   herculesstatement   "^ *\(select_cell\|select_edge\|select_net\|size\)"
  51. syn match   herculesstatement   "^ *\(text_polygon\|text_property\|area\|cut\|notch\)"
  52. syn match   herculesstatement   "^ *\(center_to_center\|inductor\|write_milkyway\)"
  53. syn match   herculesstatement   "^ *\(density\|enclose\|enc\|external\|ext\|inside_edge\)"
  54. syn match   herculesstatement   "^ *\(internal\|int\|vectorize\|select_vector\)"
  55. syn match   herculesstatement   "^ *\(length\|mask_align\|moscheck\|rescheck\)"
  56. syn match   herculesstatement   "^ *\(analysis\|buildsub\|init_lpe_db\|capacitor\)"
  57. syn match   herculesstatement   "^ *\(device\|gendev\|nmos\|pmos\|diode\|npn\|pnp\)"
  58. syn match   herculesstatement   "^ *\(resistor\|set_param\|save_property\|cap\|text    \)"
  59. syn match   herculesstatement   "^ *\(res\|connect\|disconnect\|text \|text_boolean\)"
  60. syn match   herculesstatement   "^ *\(replace_text\|create_ports\|label\|graphics\)"
  61. syn match   herculesstatement   "^ *\(save_netlist_database\|lpe_stats\|netlist\)"
  62. syn match   herculesstatement   "^ *\(spice\|graphics_property\|graphics_netlist\)"
  63. syn match   herculesstatement   "^ *\(vertex\|if\|error_property\|equate\|compare\)"
  64. syn match   herculesstatement   "^ *\(antenna_fix\|c_thru\|dev_connect_check\)"
  65. syn match   herculesstatement   "^ *\(dev_net_count\|device_count\|net_filter\)"
  66. syn match   herculesstatement   "^ *\(net_path_check\|ratio\|process_text_opens\)"
  67. syn match   herculesstatement   "^ *\(classify_edges\|write_extract_view\)"
  68.  
  69. " Hercules commands and keywords
  70. syn keyword herculesStatement   black_box_file block compare_dir equivalence
  71. syn keyword herculesStatement   format gdsin_dir group_dir group_dir_usage
  72. syn keyword herculesStatement   inlib layout_path outlib output_format
  73. syn keyword herculesStatement   output_layout_path schematic schematic_format
  74. syn keyword herculesStatement   scheme_file output_block else
  75. syn keyword herculesstatement   and or not xor andoverlap inside outside by to
  76. syn keyword herculesstatement   with connected connected_all texted_with texted
  77. syn keyword herculesstatement   by_property cutting edge_touch enclosing inside
  78. syn keyword herculesstatement   equations inside_hole interact touching vertex
  79.  
  80. " Hercules comments
  81. syn region herculesComment         start="/\*" end="\*/" contains=herculesTodo
  82. syn match herculesComment         "//.*" contains=herculesTodo
  83.  
  84. " Preprocessor directives
  85. syn match   herculesPreProc "^#.*"
  86. syn match   herculesPreProc "^@.*"
  87. syn match   herculesPreProc "macros"
  88.  
  89. " Hercules COMMENT option
  90. syn match  herculesCmdCmnt "comment.*=.*"
  91.  
  92. " Spacings, Resolutions, Ranges, Ratios, etc.
  93. syn match  herculesNumber          "-\=\<[0-9]\+L\=\>\|0[xX][0-9]\+\>"
  94.  
  95. " Parenthesis sanity checker
  96. syn region herculesZone       matchgroup=Delimiter start="(" matchgroup=Delimiter end=")" transparent contains=ALLBUT,herculesError,herculesBraceError,herculesCurlyError
  97. syn region herculesZone       matchgroup=Delimiter start="{" matchgroup=Delimiter end="}" transparent contains=ALLBUT,herculesError,herculesBraceError,herculesParenError
  98. syn region herculesZone       matchgroup=Delimiter start="\[" matchgroup=Delimiter end="]" transparent contains=ALLBUT,herculesError,herculesCurlyError,herculesParenError
  99. syn match  herculesError      "[)\]}]"
  100. syn match  herculesBraceError "[)}]"  contained
  101. syn match  herculesCurlyError "[)\]]" contained
  102. syn match  herculesParenError "[\]}]" contained
  103.  
  104. " Hercules output format
  105. syn match  herculesOutput "([0-9].*)"
  106. syn match  herculesOutput "([0-9].*\;.*)"
  107. syn match  herculesOutput "perm.*=.*"
  108. syn match  herculesOutput "temp.*=.*"
  109. syn match  herculesOutput "error\s*=\s*(.*)"
  110.  
  111. "Modify the following as needed.  The trade-off is performance versus functionality.
  112. syn sync lines=100
  113.  
  114. " Default highlighting.
  115. hi def link herculesStatement  Statement
  116. hi def link herculesType       Type
  117. hi def link herculesComment    Comment
  118. hi def link herculesPreProc    PreProc
  119. hi def link herculesTodo       Todo
  120. hi def link herculesOutput     Include
  121. hi def link herculesCmdCmnt    Identifier
  122. hi def link herculesNumber     Number
  123. hi def link herculesBraceError herculesError
  124. hi def link herculesCurlyError herculesError
  125. hi def link herculesParenError herculesError
  126. hi def link herculesError      Error
  127.  
  128. let b:current_syntax = "hercules"
  129.  
  130. " vim: ts=8
  131.